package com.ryan.mms.organization.model;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.GenericGenerator;

import com.ryan.framework.model.Model;

/**
 * Organization entity.
 * 
 * @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "organization", catalog = "framework")
public class Organization implements Model{

	private static final long serialVersionUID = 1L;

	// Fields

	private Long organizationId;
	private String organizationCode;
	private String organizationName;
	private Integer organizationLevel;
	private Long parentOrganizationId;
	private String organizationIdSequence;
	private String organizationNameSequence;
	private Integer organizationType;
	private String organizationAddress;
	private String organizationZipCode;
	private Long managerId;
	private String linkMan;
	private String linkManTel;
	private String linkManEmail;
	private String webUrl;
	private String memo;

	// Constructors

	/** default constructor */
	public Organization() {
	}

	/** minimal constructor */
	public Organization(String organizationCode, String organizationName,
			Integer organizationLevel, Long parentOrganizationId) {
		this.organizationCode = organizationCode;
		this.organizationName = organizationName;
		this.organizationLevel = organizationLevel;
		this.parentOrganizationId = parentOrganizationId;
	}

	/** full constructor */
	public Organization(String organizationCode, String organizationName,
			Integer organizationLevel, Long parentOrganizationId,
			String organizationIdSequence, String organizationNameSequence,
			Integer organizationType, String organizationAddress,
			String organizationZipCode, Long managerId, String linkMan,
			String linkManTel, String linkManEmail, String webUrl, String memo) {
		this.organizationCode = organizationCode;
		this.organizationName = organizationName;
		this.organizationLevel = organizationLevel;
		this.parentOrganizationId = parentOrganizationId;
		this.organizationIdSequence = organizationIdSequence;
		this.organizationNameSequence = organizationNameSequence;
		this.organizationType = organizationType;
		this.organizationAddress = organizationAddress;
		this.organizationZipCode = organizationZipCode;
		this.managerId = managerId;
		this.linkMan = linkMan;
		this.linkManTel = linkManTel;
		this.linkManEmail = linkManEmail;
		this.webUrl = webUrl;
		this.memo = memo;
	}

	// Property accessors
	@GenericGenerator(name = "generator", strategy = "increment")
	@Id
	@GeneratedValue(generator = "generator")
	@Column(name = "organization_id", unique = true, nullable = false)
	public Long getOrganizationId() {
		return this.organizationId;
	}

	public void setOrganizationId(Long organizationId) {
		this.organizationId = organizationId;
	}

	@Column(name = "organization_code", nullable = false, length = 12)
	public String getOrganizationCode() {
		return this.organizationCode;
	}

	public void setOrganizationCode(String organizationCode) {
		this.organizationCode = organizationCode;
	}

	@Column(name = "organization_name", nullable = false, length = 64)
	public String getOrganizationName() {
		return this.organizationName;
	}

	public void setOrganizationName(String organizationName) {
		this.organizationName = organizationName;
	}

	@Column(name = "organization_level", nullable = false)
	public Integer getOrganizationLevel() {
		return this.organizationLevel;
	}

	public void setOrganizationLevel(Integer organizationLevel) {
		this.organizationLevel = organizationLevel;
	}

	@Column(name = "parent_organization_Id", nullable = false)
	public Long getParentOrganizationId() {
		return this.parentOrganizationId;
	}

	public void setParentOrganizationId(Long parentOrganizationId) {
		this.parentOrganizationId = parentOrganizationId;
	}

	@Column(name = "organization_id_sequence", length = 512)
	public String getOrganizationIdSequence() {
		return this.organizationIdSequence;
	}

	public void setOrganizationIdSequence(String organizationIdSequence) {
		this.organizationIdSequence = organizationIdSequence;
	}

	@Column(name = "organization_name_sequence", length = 1024)
	public String getOrganizationNameSequence() {
		return this.organizationNameSequence;
	}

	public void setOrganizationNameSequence(String organizationNameSequence) {
		this.organizationNameSequence = organizationNameSequence;
	}

	@Column(name = "organization_type")
	public Integer getOrganizationType() {
		return organizationType;
	}

	public void setOrganizationType(Integer organizationType) {
		this.organizationType = organizationType;
	}

	@Column(name = "organization_address", length = 256)
	public String getOrganizationAddress() {
		return this.organizationAddress;
	}

	public void setOrganizationAddress(String organizationAddress) {
		this.organizationAddress = organizationAddress;
	}

	@Column(name = "organization_zip_code", length = 10)
	public String getOrganizationZipCode() {
		return this.organizationZipCode;
	}

	public void setOrganizationZipCode(String organizationZipCode) {
		this.organizationZipCode = organizationZipCode;
	}

	@Column(name = "manager_id")
	public Long getManagerId() {
		return this.managerId;
	}

	public void setManagerId(Long managerId) {
		this.managerId = managerId;
	}

	@Column(name = "link_man", length = 30)
	public String getLinkMan() {
		return this.linkMan;
	}

	public void setLinkMan(String linkMan) {
		this.linkMan = linkMan;
	}

	@Column(name = "link_man_tel", length = 20)
	public String getLinkManTel() {
		return this.linkManTel;
	}

	public void setLinkManTel(String linkManTel) {
		this.linkManTel = linkManTel;
	}

	@Column(name = "link_man_email", length = 128)
	public String getLinkManEmail() {
		return this.linkManEmail;
	}

	public void setLinkManEmail(String linkManEmail) {
		this.linkManEmail = linkManEmail;
	}

	@Column(name = "web_url", length = 512)
	public String getWebUrl() {
		return this.webUrl;
	}

	public void setWebUrl(String webUrl) {
		this.webUrl = webUrl;
	}

	@Column(name = "memo", length = 512)
	public String getMemo() {
		return this.memo;
	}

	public void setMemo(String memo) {
		this.memo = memo;
	}

}